package com.nbjtjc.safe.mapper.danger;

import com.nbjtjc.safe.model.danger.DangerInspect;
import com.nbjtjc.safe.model.danger.DangerInspectList;
import com.nbjtjc.util.MyMapper;
import io.swagger.models.auth.In;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface DangerInspectListMapper extends MyMapper<DangerInspectList> {

    @Delete("delete from danger_inspect_list where inspect_id=#{inspectId}")
    int deleteByInspectId(@Param("inspectId") int inspectId);


    List<DangerInspectList> search(@Param("dil") DangerInspectList dangerInspectList);

    int deleteByIds(@Param("ids") List<Integer> ids);

    @Select("select * from danger_inspect_list where inspect_id=#{inspectId}")
    List<DangerInspectList> findByInspectId(@Param("inspectId")int inspectId);

    List<DangerInspectList> findByInspectIds(@Param("inspectIds")List<Integer> inspectIds);

}